<%-- 
    Document   : acceptTwitter
    Created on : 29/Jan/2012, 18:06:35
    Author     : sexta13
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<script type="text/javascript" src="<s:url value="../../js/libs/jquery-1.7.1.min.js" />"></script>
<script type="text/javascript">
    
    $(document).ready(function() {
              

        var url = "http://192.168.160.2:8080/feedsreader/TwitterAcceptAction.action?oauthToken="+ gup('oauth_token')
        $(location).attr('href',url);
       
                
        function gup( name )
        {
            name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");
            var regexS = "[\\?&#]"+name+"=([^&#]*)";
            var regex = new RegExp( regexS );
            var results = regex.exec( window.location.href );
            if( results == null )
                return "";
            else
                return results[1];
        }
            // put all your jQuery goodness in here.
    });
</script> 